<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>结构伪类选择器</title>
    <style>
        .box{
            width: 940px;
            height: 100px;
            margin: 0 auto;
            background: yellow;
        }
        .box div{
            float: left;
            width: 300px;
            height: 100px;
            background: red;
            margin-right: 20px;
        }
        /* 最后一个孩子 */
        .box div:last-child{
            margin-right: 0px;
        }
    </style>
</head>
<body>
    <div class="box">
        <div></div>
        <div></div>
        <div class="last"></div>
    </div>
</body>
</html>